<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta content="width=device-width,initial-scale=1.0,maximum-scale=1.0,user-scalable=0" name="viewport" />
  <meta content="yes" name=" apple-mobile-web-app-capable" />
  <!-- 隐藏状态栏  -->
  <meta name="apple-mobile-web-app-capable" content="yes">
  <meta name="apple-mobile-web-app-status-bar-style" content="black-translucent" />
  <!-- <title>支付方式</title> -->
  <link rel="stylesheet" href="css/common.css">
  <link rel="stylesheet" href="css/details.css">
  <link rel="stylesheet" href="css/order-food.css">
</head>
<body>
<header>
  <div class="wrapper clearfix">
    <div class="login_fl fl">
      <a href="" class="login_icon"><img src="img/srh_icon.png" alt=""></a>
    </div>
    <h1>付款</h1>
  </div>
</header>
<section class="pay pay-food clearfix">
  <div class="pay-num">
    <p class="fl">餐点订单号:<span>QH12838112</span></p>
    <p class="fr">支付：<span>¥88.00</span></p>
  </div>
  <div class="pay_way p14">
    <div class="fl pay_icon"><img src="img/weixin_pay.png" alt=""></div>
    <p>微信支付<br><span>推荐安装微信5.0及以上版本使用</span></p>
    <div class="choise_weixin choise fr">
      <i></i>
    </div>
  </div>
</section>
<div class="p10"> 
  <input class="pay_btn" ng-click="pay()" type="button"  value="确认支付">
  <p class="remain-time"><i></i>支付剩余时间：14:59 否则订单失效呦</p>
</div>
<script src="js/jquery-1.11.2.min.js"></script>
<script src="js/bootstrap.min.js"></script>
<script src="js/angular.min.js"></script>
<script type="text/javascript" src="js/constants.js"></script>
<script src="js/common.js"></script>
<script src="js/order-foodinfo.js"></script>
<script>
    //微信支付
  function onBridgeReady(){
     WeixinJSBridge.invoke(
         'getBrandWCPayRequest', {
             "appId" : "wx2421b1c4370ec43b",     //公众号名称，由商户传入     
             "timeStamp":" 1395712654",         //时间戳，自1970年以来的秒数     
             "nonceStr" : "e61463f8efa94090b1f366cccfbbb444", //随机串     
             "package" : "prepay_id=u802345jgfjsdfgsdg888", 
             "signType" : "MD5",         //微信签名方式:     
             "paySign" : "70EA570631E4BB79628FBCA90534C63FF7FADD89" //微信签名 
         },
         function(res){     
             if(res.err_msg == "get_brand_wcpay_request:ok" ) {}     // 使用以上方式判断前端返回,微信团队郑重提示：res.err_msg将在用户支付成功后返回    ok，但并不保证它绝对可靠。 
         }
     ); 
  };
  function pay(){
    if (typeof WeixinJSBridge == "undefined"){
       if( document.addEventListener ){
           document.addEventListener('WeixinJSBridgeReady', onBridgeReady, false);
       }else if (document.attachEvent){
           document.attachEvent('WeixinJSBridgeReady', onBridgeReady); 
           document.attachEvent('onWeixinJSBridgeReady', onBridgeReady);
       }
    }else{
       onBridgeReady();
    }
  }
</script>
</body>
<span style="display:none;"><script type="text/javascript">var cnzz_protocol = (("https:" == document.location.protocol) ? " https://" : " http://");document.write(unescape("%3Cspan id='cnzz_stat_icon_1255764485'%3E%3C/span%3E%3Cscript src='" + cnzz_protocol + "s95.cnzz.com/z_stat.php%3Fid%3D1255764485%26show%3Dpic1' type='text/javascript'%3E%3C/script%3E"));</script></span>
<script>
    _maq.push(['_setMaq', 'order-payway']);
</script>
</html>